package com.zoshine.zzg.pojo.pojostatus;

import java.util.Objects;

/**
 * 组织类型枚举
 * @author 贾俊峰
 * @time 2017/7/6 20:59
 */
public enum OrgType {
    Prison(1, "监狱/看守所"),
//    Detention_house(1, "监狱/看守所"),
    Supplier(2,"供应商");

    private int value;
    private String desc;
    OrgType(final int value, final String desc) {
        this.value = value;
        this.desc = desc;
    }
    public int getValue() {
        return this.value;
    }
    public static String getDesc(Integer value) {
        for (OrgType orgType : OrgType.values()) {
            if (Objects.equals(orgType.value, value)) {
                return orgType.desc;
            }
        }
        return null;
    }
}
